<?xml version="1.0" encoding="UTF-8" ?>
<?oracle-xsl-mapper
  <!-- SPECIFICATION OF MAP SOURCES AND TARGETS, DO NOT MODIFY. -->
  <mapSources>
    <source type="XSD">
      <schema location="../xsd/UBPerson_Service_table.xsd"/>
      <rootElement name="XxsaisStaffInfoCollection" namespace="http://xmlns.oracle.com/pcbpel/adapter/db/top/UBPerson_Service"/>
    </source>
  </mapSources>
  <mapTargets>
    <target type="XSD">
      <schema location="http://moroka.ub.bw:7001/PSIGW/PeopleSoftServiceListeningConnector/UB_STAFF.V1.xsd"/>
      <rootElement name="UB_STAFF" namespace="http://xmlns.oracle.com/Enterprise/CSM/schemas/UB_STAFF.V1"/>
    </target>
  </mapTargets>
  <!-- GENERATED BY ORACLE XSL MAPPER 11.1.1.2.0(build 091103.1205.1216) AT [MON SEP 02 12:38:31 CAT 2013]. -->
?>
<xsl:stylesheet version="1.0"
                xmlns:xpath20="http://www.oracle.com/XSL/Transform/java/oracle.tip.pc.services.functions.Xpath20"
                xmlns:bpws="http://schemas.xmlsoap.org/ws/2003/03/business-process/"
                xmlns:mhdr="http://www.oracle.com/XSL/Transform/java/oracle.tip.mediator.service.common.functions.MediatorExtnFunction"
                xmlns:oraext="http://www.oracle.com/XSL/Transform/java/oracle.tip.pc.services.functions.ExtFunc"
                xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
                xmlns:dvm="http://www.oracle.com/XSL/Transform/java/oracle.tip.dvm.LookupValue"
                xmlns:hwf="http://xmlns.oracle.com/bpel/workflow/xpath"
                xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
                xmlns:med="http://schemas.oracle.com/mediator/xpath"
                xmlns:ids="http://xmlns.oracle.com/bpel/services/IdentityService/xpath"
                xmlns:xdk="http://schemas.oracle.com/bpel/extension/xpath/function/xdk"
                xmlns:xref="http://www.oracle.com/XSL/Transform/java/oracle.tip.xref.xpath.XRefXPathFunctions"
                xmlns:xsd="http://www.w3.org/2001/XMLSchema"
                xmlns:ns0="http://xmlns.oracle.com/pcbpel/adapter/db/top/UBPerson_Service"
                xmlns:ns1="http://xmlns.oracle.com/Enterprise/CSM/schemas/UB_STAFF.V1"
                xmlns:ora="http://schemas.oracle.com/xpath/extension"
                xmlns:socket="http://www.oracle.com/XSL/Transform/java/oracle.tip.adapter.socket.ProtocolTranslator"
                xmlns:UB_STAFF_PART.V1="http://xmlns.oracle.com/Enterprise/CSM/schemas/UB_STAFF_PART.V1"
                xmlns:ldap="http://schemas.oracle.com/xpath/extension/ldap"
                exclude-result-prefixes="xsi xsl xsd ns0 ns1 UB_STAFF_PART.V1 xpath20 bpws mhdr oraext dvm hwf med ids xdk xref ora socket ldap">
  <xsl:template match="/">
    <ns1:UB_STAFF>
      <ns1:UB_STAFF_PART>
        <UB_STAFF_PART.V1:UB_INT_STAFF_WK>
          <xsl:attribute name="class">
            <xsl:text disable-output-escaping="no">R</xsl:text>
          </xsl:attribute>
          <UB_STAFF_PART.V1:EMPLID>
            <xsl:value-of select="/ns0:XxsaisStaffInfoCollection/ns0:XxsaisStaffInfo/ns0:employeeNumber"/>
          </UB_STAFF_PART.V1:EMPLID>
          <UB_STAFF_PART.V1:NAME_PREFIX>
            <xsl:value-of select="/ns0:XxsaisStaffInfoCollection/ns0:XxsaisStaffInfo/ns0:namePrefix"/>
          </UB_STAFF_PART.V1:NAME_PREFIX>
          <UB_STAFF_PART.V1:FIRST_NAME>
            <xsl:value-of select="/ns0:XxsaisStaffInfoCollection/ns0:XxsaisStaffInfo/ns0:firstName"/>
          </UB_STAFF_PART.V1:FIRST_NAME>
          <UB_STAFF_PART.V1:LAST_NAME>
            <xsl:value-of select="/ns0:XxsaisStaffInfoCollection/ns0:XxsaisStaffInfo/ns0:surname"/>
          </UB_STAFF_PART.V1:LAST_NAME>
          <UB_STAFF_PART.V1:NATIONAL_ID>
            <xsl:value-of select="/ns0:XxsaisStaffInfoCollection/ns0:XxsaisStaffInfo/ns0:nationalId"/>
          </UB_STAFF_PART.V1:NATIONAL_ID>
          <UB_STAFF_PART.V1:UB_CNTRY_2CHAR>
            <xsl:value-of select="/ns0:XxsaisStaffInfoCollection/ns0:XxsaisStaffInfo/ns0:nationalIdCountry"/>
          </UB_STAFF_PART.V1:UB_CNTRY_2CHAR>
          <UB_STAFF_PART.V1:NATIONAL_ID_TYPE>
            <xsl:value-of select="/ns0:XxsaisStaffInfoCollection/ns0:XxsaisStaffInfo/ns0:nationalIdType"/>
          </UB_STAFF_PART.V1:NATIONAL_ID_TYPE>
          <UB_STAFF_PART.V1:SEX>
            <xsl:value-of select="/ns0:XxsaisStaffInfoCollection/ns0:XxsaisStaffInfo/ns0:gender"/>
          </UB_STAFF_PART.V1:SEX>
          <UB_STAFF_PART.V1:BIRTHDATE>
            <xsl:value-of select='xpath20:format-dateTime(/ns0:XxsaisStaffInfoCollection/ns0:XxsaisStaffInfo/ns0:dateOfBirth,"[Y0001]-[M01]-[D01]")'/>
          </UB_STAFF_PART.V1:BIRTHDATE>
          <UB_STAFF_PART.V1:ADDRESS1>
            <xsl:value-of select="substring(/ns0:XxsaisStaffInfoCollection/ns0:XxsaisStaffInfo/ns0:postalAddress,1,55)"/>
          </UB_STAFF_PART.V1:ADDRESS1>
          <UB_STAFF_PART.V1:ADDRESS2>
            <xsl:value-of select="substring(/ns0:XxsaisStaffInfoCollection/ns0:XxsaisStaffInfo/ns0:postalAddress,56.0,55.0)"/>
          </UB_STAFF_PART.V1:ADDRESS2>
          <UB_STAFF_PART.V1:ADDRESS3>
            <xsl:value-of select="substring(/ns0:XxsaisStaffInfoCollection/ns0:XxsaisStaffInfo/ns0:postalAddress,111.0,55.0)"/>
          </UB_STAFF_PART.V1:ADDRESS3>
          <UB_STAFF_PART.V1:ADDRESS4>
            <xsl:value-of select="substring(/ns0:XxsaisStaffInfoCollection/ns0:XxsaisStaffInfo/ns0:postalAddress,116.0,55.0)"/>
          </UB_STAFF_PART.V1:ADDRESS4>
          <UB_STAFF_PART.V1:WORK_PHONE>
            <xsl:value-of select="/ns0:XxsaisStaffInfoCollection/ns0:XxsaisStaffInfo/ns0:phoneNumber"/>
          </UB_STAFF_PART.V1:WORK_PHONE>
          <UB_STAFF_PART.V1:EMAIL_ADDR>
            <xsl:value-of select="/ns0:XxsaisStaffInfoCollection/ns0:XxsaisStaffInfo/ns0:emailAddress"/>
          </UB_STAFF_PART.V1:EMAIL_ADDR>
          <UB_STAFF_PART.V1:DEPTID>
            <xsl:value-of select="/ns0:XxsaisStaffInfoCollection/ns0:XxsaisStaffInfo/ns0:department"/>
          </UB_STAFF_PART.V1:DEPTID>
          <UB_STAFF_PART.V1:START_HIRE_DT>
            <xsl:value-of select='xpath20:format-dateTime(/ns0:XxsaisStaffInfoCollection/ns0:XxsaisStaffInfo/ns0:originalDateOfHire,"[Y0001]-[M01]-[D01]")'/>
          </UB_STAFF_PART.V1:START_HIRE_DT>
        </UB_STAFF_PART.V1:UB_INT_STAFF_WK>
      </ns1:UB_STAFF_PART>
    </ns1:UB_STAFF>
  </xsl:template>
</xsl:stylesheet>
